import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { DevUIModule } from 'ng-devui';
import { ButtonModule } from 'ng-devui/button';
import { BaseComponent } from './pages/base/base.component';
import { TextInputModule } from 'ng-devui/text-input';
import { FormsModule } from '@angular/forms';
import { AlertModule } from 'ng-devui/alert';
import { ModalModule } from 'ng-devui/modal';
import { CheckBoxModule } from 'ng-devui';
import { NgrxComponent } from './pages/ngrx/ngrx.component';
import { StoreModule } from '@ngrx/store';
import { reducers, metaReducers } from './store';
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
import { environment } from '../environments/environment';
@NgModule({
  declarations: [AppComponent, BaseComponent, NgrxComponent],
  imports: [
    FormsModule,
    BrowserModule,
    AppRoutingModule,
    BrowserAnimationsModule,
    // DevUIModule, // 全局引入，启动太慢
    ButtonModule,
    TextInputModule,
    AlertModule,
    ModalModule,
    CheckBoxModule,
    StoreModule.forRoot(reducers, { metaReducers }),
    !environment.production ? StoreDevtoolsModule.instrument() : [],
  ],
  providers: [],
  bootstrap: [AppComponent],
})
export class AppModule {}
